<?php

class BookStatus
{
    const BOOKED = 1;
    const AVAILABLE = 0;
    const UNAVAILABLE = -1;
    
    public $status;
    public $bookableResourceId;
    public $byMe = false;
    public $cancelable = false;
    
    public function isBooked()
    {
        return $this->status == self::BOOKED;
    }
    
    public function isAvailable()
    {
        return $this->status == self::AVAILABLE;
    }
    
    public function isUnavailable()
    {
        return $this->status == self::UNAVAILABLE;
    }
    
    public function isByMe()
    {
        return $this->byMe;
    }
    
    public function isCancelable()
    {
        return $this->cancelable;
    }
}

